package com.newdjk.newdoctor.adapter;

import android.content.Context;

import androidx.annotation.NonNull;
import androidx.fragment.app.Fragment;
import androidx.fragment.app.FragmentManager;
import androidx.fragment.app.FragmentPagerAdapter;

import com.newdjk.newdoctor.GonggaoActivity;

import java.util.List;

public class MyAdapter extends FragmentPagerAdapter {

    private Context context;
    private List<Fragment> mList;
    public MyAdapter(@NonNull FragmentManager fm, List<Fragment> list) {
        super(fm);
        mList = list;
    }

    @NonNull
    @Override
    public Fragment getItem(int position) {
        return  mList.get(position);
    }

    @Override
    public int getCount() {
        return mList.size();
    }
}
